package net.csdn.business.common.utils;

import net.csdn.business.common.domain.vo.UserVo;
import org.apache.commons.lang3.ObjectUtils;

/**
 * @author likun
 * @date 2023/5/31 10:36
 */
public class SafeUtil {
    public static void filterUserInfo(final UserVo user) {
        if (ObjectUtils.isEmpty(user)) {
            return;
        }
        user.setLastIP(null);
        user.setLastLogin(null);
        user.setLastPwdUpdateTime(null);
        user.setLoginsCount(null);
        user.setEmail(null);
        user.setPhone(null);
        // user.setEmail(DesensitizedUtil.email(user.getEmail()));
        // user.setPhone(DesensitizedUtil.mobilePhone(user.getPhone()));
    }
}